
package com.hc.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.hc.dao.IArticleDao;
import com.hc.domain.Article;
import com.hc.service.IArticleService;
@Service("articleService")
public class ArticleServiceImpl implements IArticleService {
	@Resource
	private IArticleDao articleDao;

	@Override
	public void save(Article art) {
		articleDao.saveArticle(art);
	}

	@Override
	public List<Article> findPageByType(int page, int count, String type) {
		return articleDao.findPageByType(page,count,type);
		
	}

	@Override
	public Article getById(int id) {
		return articleDao.getById(id);
		
	}

	@Override
	public void update(Article art) {
		articleDao.updateArt(art);
	}

	@Override
	public List<Article> findPageByLikeSql(int page, int count, String type, String words) {
		return articleDao.findPageByLikeSql(page,count,type,words);
		
	}

}

